﻿using System;
using System.Collections;
using System.Collections.Generic;

namespace Poly2Tri
{
	// Token: 0x02000407 RID: 1031
	public class TriangulationPointEnumerator : IEnumerator<TriangulationPoint>, IEnumerator, IDisposable
	{
		// Token: 0x06001CCC RID: 7372 RVA: 0x000B358C File Offset: 0x000B178C
		public TriangulationPointEnumerator(IList<Point2D> points)
		{
			this.mPoints = points;
		}

		// Token: 0x06001CCD RID: 7373 RVA: 0x000B35A2 File Offset: 0x000B17A2
		public bool MoveNext()
		{
			this.position++;
			return this.position < this.mPoints.Count;
		}

		// Token: 0x06001CCE RID: 7374 RVA: 0x000B35C5 File Offset: 0x000B17C5
		public void Reset()
		{
			this.position = -1;
		}

		// Token: 0x06001CCF RID: 7375 RVA: 0x00002973 File Offset: 0x00000B73
		void IDisposable.Dispose()
		{
		}

		// Token: 0x17000423 RID: 1059
		// (get) Token: 0x06001CD0 RID: 7376 RVA: 0x000B35CE File Offset: 0x000B17CE
		object IEnumerator.Current
		{
			get
			{
				return this.Current;
			}
		}

		// Token: 0x17000424 RID: 1060
		// (get) Token: 0x06001CD1 RID: 7377 RVA: 0x000B35D6 File Offset: 0x000B17D6
		public TriangulationPoint Current
		{
			get
			{
				if (this.position < 0 || this.position >= this.mPoints.Count)
				{
					return null;
				}
				return this.mPoints[this.position] as TriangulationPoint;
			}
		}

		// Token: 0x04001DAB RID: 7595
		protected IList<Point2D> mPoints;

		// Token: 0x04001DAC RID: 7596
		protected int position = -1;
	}
}
